Integrand size = 19, antiderivative size = 151 \[ \int (a+a \sec (c+d x)) \tan ^9(c+d x) \, dx=-\frac {a \log (\cos (c+d x))}{d}+\frac {a \sec (c+d x)}{d}-\frac {2 a \sec ^2(c+d x)}{d}-\frac {4 a \sec ^3(c+d x)}{3 d}+\frac {3 a \sec ^4(c+d x)}{2 d}+\frac {6 a \sec ^5(c+d x)}{5 d}-\frac {2 a \sec ^6(c+d x)}{3 d}-\frac {4 a \sec ^7(c+d x)}{7 d}+\frac {a \sec ^8(c+d x)}{8 d}+\frac {a \sec ^9(c+d x)}{9 d} \]
[Out]
Time = 0.08 (sec) , antiderivative size = 151, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.105, Rules used = {3964, 90} \[ \int (a+a \sec (c+d x)) \tan ^9(c+d x) \, dx=\frac {a \sec ^9(c+d x)}{9 d}+\frac {a \sec ^8(c+d x)}{8 d}-\frac {4 a \sec ^7(c+d x)}{7 d}-\frac {2 a \sec ^6(c+d x)}{3 d}+\frac {6 a \sec ^5(c+d x)}{5 d}+\frac {3 a \sec ^4(c+d x)}{2 d}-\frac {4 a \sec ^3(c+d x)}{3 d}-\frac {2 a \sec ^2(c+d x)}{d}+\frac {a \sec (c+d x)}{d}-\frac {a \log (\cos (c+d x))}{d} \]
[In]
[Out]
Rule 90
Rule 3964
Rubi steps \begin{align*} \text {integral}& = -\frac {\text {Subst}\left (\int \frac {(a-a x)^4 (a+a x)^5}{x^{10}} \, dx,x,\cos (c+d x)\right )}{a^8 d} \\ & = -\frac {\text {Subst}\left (\int \left (\frac {a^9}{x^{10}}+\frac {a^9}{x^9}-\frac {4 a^9}{x^8}-\frac {4 a^9}{x^7}+\frac {6 a^9}{x^6}+\frac {6 a^9}{x^5}-\frac {4 a^9}{x^4}-\frac {4 a^9}{x^3}+\frac {a^9}{x^2}+\frac {a^9}{x}\right ) \, dx,x,\cos (c+d x)\right )}{a^8 d} \\ & = -\frac {a \log (\cos (c+d x))}{d}+\frac {a \sec (c+d x)}{d}-\frac {2 a \sec ^2(c+d x)}{d}-\frac {4 a \sec ^3(c+d x)}{3 d}+\frac {3 a \sec ^4(c+d x)}{2 d}+\frac {6 a \sec ^5(c+d x)}{5 d}-\frac {2 a \sec ^6(c+d x)}{3 d}-\frac {4 a \sec ^7(c+d x)}{7 d}+\frac {a \sec ^8(c+d x)}{8 d}+\frac {a \sec ^9(c+d x)}{9 d} \\ \end{align*}
Time = 0.57 (sec) , antiderivative size = 134, normalized size of antiderivative = 0.89 \[ \int (a+a \sec (c+d x)) \tan ^9(c+d x) \, dx=\frac {a \sec (c+d x)}{d}-\frac {4 a \sec ^3(c+d x)}{3 d}+\frac {6 a \sec ^5(c+d x)}{5 d}-\frac {4 a \sec ^7(c+d x)}{7 d}+\frac {a \sec ^9(c+d x)}{9 d}-\frac {a \left (24 \log (\cos (c+d x))+12 \tan ^2(c+d x)-6 \tan ^4(c+d x)+4 \tan ^6(c+d x)-3 \tan ^8(c+d x)\right )}{24 d} \]
[In]
[Out]
Time = 1.46 (sec) , antiderivative size = 100, normalized size of antiderivative = 0.66
method | result | size |
derivativedivides | \(\frac {a \left (\frac {\sec \left (d x +c \right )^{9}}{9}+\frac {\sec \left (d x +c \right )^{8}}{8}-\frac {4 \sec \left (d x +c \right )^{7}}{7}-\frac {2 \sec \left (d x +c \right )^{6}}{3}+\frac {6 \sec \left (d x +c \right )^{5}}{5}+\frac {3 \sec \left (d x +c \right )^{4}}{2}-\frac {4 \sec \left (d x +c \right )^{3}}{3}-2 \sec \left (d x +c \right )^{2}+\sec \left (d x +c \right )+\ln \left (\sec \left (d x +c \right )\right )\right )}{d}\) | \(100\) |
default | \(\frac {a \left (\frac {\sec \left (d x +c \right )^{9}}{9}+\frac {\sec \left (d x +c \right )^{8}}{8}-\frac {4 \sec \left (d x +c \right )^{7}}{7}-\frac {2 \sec \left (d x +c \right )^{6}}{3}+\frac {6 \sec \left (d x +c \right )^{5}}{5}+\frac {3 \sec \left (d x +c \right )^{4}}{2}-\frac {4 \sec \left (d x +c \right )^{3}}{3}-2 \sec \left (d x +c \right )^{2}+\sec \left (d x +c \right )+\ln \left (\sec \left (d x +c \right )\right )\right )}{d}\) | \(100\) |
parts | \(\frac {a \left (\frac {\tan \left (d x +c \right )^{8}}{8}-\frac {\tan \left (d x +c \right )^{6}}{6}+\frac {\tan \left (d x +c \right )^{4}}{4}-\frac {\tan \left (d x +c \right )^{2}}{2}+\frac {\ln \left (1+\tan \left (d x +c \right )^{2}\right )}{2}\right )}{d}+\frac {a \left (\frac {\sec \left (d x +c \right )^{9}}{9}-\frac {4 \sec \left (d x +c \right )^{7}}{7}+\frac {6 \sec \left (d x +c \right )^{5}}{5}-\frac {4 \sec \left (d x +c \right )^{3}}{3}+\sec \left (d x +c \right )\right )}{d}\) | \(113\) |
risch | \(i a x +\frac {2 i a c}{d}+\frac {2 a \left (315 \,{\mathrm e}^{17 i \left (d x +c \right )}-1260 \,{\mathrm e}^{16 i \left (d x +c \right )}+840 \,{\mathrm e}^{15 i \left (d x +c \right )}-5040 \,{\mathrm e}^{14 i \left (d x +c \right )}+4788 \,{\mathrm e}^{13 i \left (d x +c \right )}-14280 \,{\mathrm e}^{12 i \left (d x +c \right )}+5112 \,{\mathrm e}^{11 i \left (d x +c \right )}-21420 \,{\mathrm e}^{10 i \left (d x +c \right )}+10658 \,{\mathrm e}^{9 i \left (d x +c \right )}-21420 \,{\mathrm e}^{8 i \left (d x +c \right )}+5112 \,{\mathrm e}^{7 i \left (d x +c \right )}-14280 \,{\mathrm e}^{6 i \left (d x +c \right )}+4788 \,{\mathrm e}^{5 i \left (d x +c \right )}-5040 \,{\mathrm e}^{4 i \left (d x +c \right )}+840 \,{\mathrm e}^{3 i \left (d x +c \right )}-1260 \,{\mathrm e}^{2 i \left (d x +c \right )}+315 \,{\mathrm e}^{i \left (d x +c \right )}\right )}{315 d \left ({\mathrm e}^{2 i \left (d x +c \right )}+1\right )^{9}}-\frac {a \ln \left ({\mathrm e}^{2 i \left (d x +c \right )}+1\right )}{d}\) | \(240\) |
[In]
[Out]
none
Time = 0.29 (sec) , antiderivative size = 123, normalized size of antiderivative = 0.81 \[ \int (a+a \sec (c+d x)) \tan ^9(c+d x) \, dx=-\frac {2520 \, a \cos \left (d x + c\right )^{9} \log \left (-\cos \left (d x + c\right )\right ) - 2520 \, a \cos \left (d x + c\right )^{8} + 5040 \, a \cos \left (d x + c\right )^{7} + 3360 \, a \cos \left (d x + c\right )^{6} - 3780 \, a \cos \left (d x + c\right )^{5} - 3024 \, a \cos \left (d x + c\right )^{4} + 1680 \, a \cos \left (d x + c\right )^{3} + 1440 \, a \cos \left (d x + c\right )^{2} - 315 \, a \cos \left (d x + c\right ) - 280 \, a}{2520 \, d \cos \left (d x + c\right )^{9}} \]
[In]
[Out]
Time = 1.59 (sec) , antiderivative size = 184, normalized size of antiderivative = 1.22 \[ \int (a+a \sec (c+d x)) \tan ^9(c+d x) \, dx=\begin {cases} \frac {a \log {\left (\tan ^{2}{\left (c + d x \right )} + 1 \right )}}{2 d} + \frac {a \tan ^{8}{\left (c + d x \right )} \sec {\left (c + d x \right )}}{9 d} + \frac {a \tan ^{8}{\left (c + d x \right )}}{8 d} - \frac {8 a \tan ^{6}{\left (c + d x \right )} \sec {\left (c + d x \right )}}{63 d} - \frac {a \tan ^{6}{\left (c + d x \right )}}{6 d} + \frac {16 a \tan ^{4}{\left (c + d x \right )} \sec {\left (c + d x \right )}}{105 d} + \frac {a \tan ^{4}{\left (c + d x \right )}}{4 d} - \frac {64 a \tan ^{2}{\left (c + d x \right )} \sec {\left (c + d x \right )}}{315 d} - \frac {a \tan ^{2}{\left (c + d x \right )}}{2 d} + \frac {128 a \sec {\left (c + d x \right )}}{315 d} & \text {for}\: d \neq 0 \\x \left (a \sec {\left (c \right )} + a\right ) \tan ^{9}{\left (c \right )} & \text {otherwise} \end {cases} \]
[In]
[Out]
none
Time = 0.21 (sec) , antiderivative size = 116, normalized size of antiderivative = 0.77 \[ \int (a+a \sec (c+d x)) \tan ^9(c+d x) \, dx=-\frac {2520 \, a \log \left (\cos \left (d x + c\right )\right ) - \frac {2520 \, a \cos \left (d x + c\right )^{8} - 5040 \, a \cos \left (d x + c\right )^{7} - 3360 \, a \cos \left (d x + c\right )^{6} + 3780 \, a \cos \left (d x + c\right )^{5} + 3024 \, a \cos \left (d x + c\right )^{4} - 1680 \, a \cos \left (d x + c\right )^{3} - 1440 \, a \cos \left (d x + c\right )^{2} + 315 \, a \cos \left (d x + c\right ) + 280 \, a}{\cos \left (d x + c\right )^{9}}}{2520 \, d} \]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. 293 vs. \(2 (137) = 274\).
Time = 6.42 (sec) , antiderivative size = 293, normalized size of antiderivative = 1.94 \[ \int (a+a \sec (c+d x)) \tan ^9(c+d x) \, dx=\frac {2520 \, a \log \left ({\left | -\frac {\cos \left (d x + c\right ) - 1}{\cos \left (d x + c\right ) + 1} + 1 \right |}\right ) - 2520 \, a \log \left ({\left | -\frac {\cos \left (d x + c\right ) - 1}{\cos \left (d x + c\right ) + 1} - 1 \right |}\right ) + \frac {9177 \, a + \frac {87633 \, a {\left (\cos \left (d x + c\right ) - 1\right )}}{\cos \left (d x + c\right ) + 1} + \frac {375732 \, a {\left (\cos \left (d x + c\right ) - 1\right )}^{2}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{2}} + \frac {953988 \, a {\left (\cos \left (d x + c\right ) - 1\right )}^{3}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{3}} + \frac {1594782 \, a {\left (\cos \left (d x + c\right ) - 1\right )}^{4}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{4}} + \frac {1336734 \, a {\left (\cos \left (d x + c\right ) - 1\right )}^{5}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{5}} + \frac {781956 \, a {\left (\cos \left (d x + c\right ) - 1\right )}^{6}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{6}} + \frac {302004 \, a {\left (\cos \left (d x + c\right ) - 1\right )}^{7}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{7}} + \frac {69201 \, a {\left (\cos \left (d x + c\right ) - 1\right )}^{8}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{8}} + \frac {7129 \, a {\left (\cos \left (d x + c\right ) - 1\right )}^{9}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{9}}}{{\left (\frac {\cos \left (d x + c\right ) - 1}{\cos \left (d x + c\right ) + 1} + 1\right )}^{9}}}{2520 \, d} \]
[In]
[Out]
Time = 17.95 (sec) , antiderivative size = 259, normalized size of antiderivative = 1.72 \[ \int (a+a \sec (c+d x)) \tan ^9(c+d x) \, dx=\frac {2\,a\,\mathrm {atanh}\left ({\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2\right )}{d}-\frac {2\,a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{16}-18\,a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{14}+\frac {218\,a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{12}}{3}-174\,a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{10}+\frac {1382\,a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^8}{5}-\frac {2114\,a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^6}{15}+\frac {1654\,a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^4}{35}-\frac {326\,a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2}{35}+\frac {256\,a}{315}}{d\,\left ({\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{18}-9\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{16}+36\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{14}-84\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{12}+126\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^{10}-126\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^8+84\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^6-36\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^4+9\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2-1\right )} \]
[In]
[Out]